﻿// --------------------------------------------------------------------------------------------------------------------
// <copyright file="IHierarchyItem.cs" company="">
//   
// </copyright>
// <summary>
//   The HierarchyItem interface.
// </summary>
// --------------------------------------------------------------------------------------------------------------------

namespace Libium.Components
{
    using System.Collections.Generic;

    /// <summary>
    ///   The HierarchyItem interface.
    /// </summary>
    public interface IHierarchyItem
    {
        #region Public Properties

        /// <summary>
        ///   Gets the children.
        /// </summary>
        IEnumerable<IHierarchyItem> Children { get; }

        /// <summary>
        ///   Gets a value indicating whether is child.
        /// </summary>
        bool IsChild { get; }

        /// <summary>
        ///   Gets a value indicating whether is leaf.
        /// </summary>
        bool IsLeaf { get; }

        /// <summary>
        ///   Gets a value indicating whether is parent.
        /// </summary>
        bool IsParent { get; }

        /// <summary>
        ///   Gets a value indicating whether is root.
        /// </summary>
        bool IsRoot { get; }

        /// <summary>
        ///   Gets the parent.
        /// </summary>
        IHierarchyItem Parent { get; }

        /// <summary>
        ///   Gets the root.
        /// </summary>
        IHierarchyItem Root { get; }

        #endregion
    }
}